home *** CD-ROM | disk | FTP | other *** search
- // Copyright (c) 1994, University of Kansas, All Rights Reserved
- //
- // Class: TDiskView
- // Include File: tdiskvie.h
- // Purpose: Display the amount of free disk space.
- // Remarks/Portability/Dependencies/Restrictions:
- // Revision History:
- // 02-18-94 created
- #include"tdiskvie.h"
- #include<strstrea.h>
- #include<iomanip.h>
-
- void TDiskView::draw() {
- // Purpose: Redraw the view.
- // Arguments: none
- // Return Value: none
- // Remarks/Portability/Dependencies/Restrictions:
- // Revision History:
- // 02-18-94 created
-
- TDrawBuffer TDB;
- char c = getColor(2);
-
- // Convert to a string.
- ostrstream totalStr(DiskInAscii, sizeof(DiskInAscii));
- totalStr << setw(12) << uli_pres << ends;
-
- // First clear then redraw.
- TDB.moveChar(0, ' ', c, size.x);
- TDB.moveStr(0, DiskInAscii, c);
- writeLine(0, 0, size.x, 1, TDB);
- }